package com.college_career_system.service;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.IService;
import com.college_career_system.pojo.dto.UsersLoginDTO;
import org.springframework.stereotype.Service;

import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import javax.swing.*;
import java.io.IOException;

/**
 * @Author: Empty
 * @Date: 2022-12-06-19:32
 * @Description:
 */
public interface UsersLoginService  {

    /**
     * 用户登录
     * @param usersLoginDTO
     * @return
     */
    JSONObject login(UsersLoginDTO usersLoginDTO);

    /**
     * 得到验证码
     * @return
     */
    JSONObject getCode(HttpSession session, HttpServletResponse response) throws IOException;

    /**
     * 根据采用验证码登录
     * @param session
     * @param response
     * @param usersLoginDTO
     * @return
     */
    JSONObject loginByCode(HttpSession session, HttpServletResponse response, UsersLoginDTO usersLoginDTO);
}
